package com.leyou.config;

//import com.alibaba.druid.pool.DruidDataSource;
//import org.springframework.boot.context.properties.EnableConfigurationProperties;
//import org.springframework.context.annotation.Bean;
//import org.springframework.context.annotation.Configuration;
//
//import javax.sql.DataSource;
//
///**
// * @author XiaoLuo
// * @ClassName: JdbcConfig
// * @Description: ${todo}
// * @date 2019/4/5 14:29
// */
//@Configuration
//@EnableConfigurationProperties(JdbcProperties.class)
//public class JdbcConfig {
//    @Bean
//    public DataSource dataSource(JdbcProperties jdbc) {
//        DruidDataSource dataSource = new DruidDataSource();
//        dataSource.setUrl(jdbc.getUrl());
//        dataSource.setDriverClassName(jdbc.getDriverClassName());
//        dataSource.setUsername(jdbc.getUsername());
//        dataSource.setPassword(jdbc.getPassword());
//        return dataSource;
//    }
//}
